/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package parse;

import util.Pair;
import java.util.List;
import drt.DrtExpression;

/**
 *
 * @author phong
 */
public abstract class CCGNode {
    
    static int tabs = 0;

    Category cat;
    DrtExpression sem;

    int tokStartId;
    int tokEndId;
    double prob;

    public CCGNode(Category cat, DrtExpression sem) {
        this.cat = cat;
        this.sem = sem;
        this.tokStartId = Integer.MAX_VALUE;
        this.tokEndId = -1;
        this.prob = 0;
    }

    public Category getCat() {
        return this.cat;
    }
    
    public DrtExpression getSem() {
        return this.sem;
    }
    
    public double getProb() {
        return this.prob;
    }
    
    public abstract void updateTokIDs();
    
    public abstract void updateSem();
    
    public Pair<Integer,Integer> getTokIDs() {
        return new Pair<Integer,Integer>(this.tokStartId, this.tokEndId);
    }    
    
    public abstract List<CCGLexNode> getLexNodes();
    
    public abstract CCGNode[] getChildren();
    
    public abstract void putInChart(Chart chart);
}
